bash Cookbook: Solutions and Examples for bash Users

bash Cookbook: Solutions and Examples for bash Users

  • Downloads:9968
  • Type:Epub+TxT+PDF+Mobi
  • Create Date:2021-03-07 03:16:39
  • Update Date:2025-09-07
  • Status:finish
  • Author:Carl Albing
  • ISBN:B076TZTYMR
  • Environment:PC/Android/iPhone/iPad/Kindle

Summary

For system administrators, programmers, and end users, shell command or carefully crafted shell script can save you time and effort, or facilitate consistency and repeatability for a variety of common tasks。 This cookbook provides more than 300 practical recipes for using bash, the popular Unix shell that enables you to harness and customize the power of any Unix or Linux system。

Ideal for new and experienced users alike—including proficient Windows users and sysadmins—this updated second edition helps you solve a wide range of problems。 You’ll learn ways to handle input/output, file manipulation, program execution, administrative tasks, and many other challenges。 Each recipe includes one or more scripting examples and a discussion of why the solution works。

You’ll find recipes for problems including:

Standard output and input, and executing commands Shell variables, shell logic, and arithmetic Intermediate shell tools and advanced scripting Searching for files with findlocate, and slocate Working with dates and times Creating shell scripts for various end-user tasks Working with tasks that require parsing Writing secure shell scripts Configuring and customizing bash

Download

Reviews

Anna

Skimmed。 Mostly a reference, but gave me a couple of ideas

Benjamin

There is a new edition of this slated to released shortly。 I hope all the examples that fail to quote variable expansions will be fixed in there。Other than that, I found a few nice practices to incorporate into my own workflows。

Richard

Don't fear the command line! A large part of the time I spend using computers is spent on the command line。 This is partly because I look after various servers, and partly because I choose to use a command line heavy interface。 Bash is my command line of choice, and this book is full of handy scripts and guidance on how to write your own in order to make the most of its abilities。 Well written and mostly well formatted (not always easy on kindle versions of coding books)。 The examples are also w Don't fear the command line! A large part of the time I spend using computers is spent on the command line。 This is partly because I look after various servers, and partly because I choose to use a command line heavy interface。 Bash is my command line of choice, and this book is full of handy scripts and guidance on how to write your own in order to make the most of its abilities。 Well written and mostly well formatted (not always easy on kindle versions of coding books)。 The examples are also well paced。 。。。more

Kerszi

Książka dosyć gruba, przy tym dosyć droga。 Mam wrażenie, że od ilości stron wydawcy ustalają cenę i tych stron dali za dużo na siłę。 W każdym rozdziale znajdują się odnośniki, czasem treści kodów źródłowych itd, to rozdmuchuje lekturę。 Np są 3 odnośniki i jest już 1 strona。 Jest też dużo dodatków。 Mimo, że wydana w 2007 roku i jest dosyć stary Bash, lektura jest świetna。 Jak ktoś się uczył programowania skryptów w Bashu i czegoś nie wie, z niej się dowie。 W niej jest praktycznie wszystko co było Książka dosyć gruba, przy tym dosyć droga。 Mam wrażenie, że od ilości stron wydawcy ustalają cenę i tych stron dali za dużo na siłę。 W każdym rozdziale znajdują się odnośniki, czasem treści kodów źródłowych itd, to rozdmuchuje lekturę。 Np są 3 odnośniki i jest już 1 strona。 Jest też dużo dodatków。 Mimo, że wydana w 2007 roku i jest dosyć stary Bash, lektura jest świetna。 Jak ktoś się uczył programowania skryptów w Bashu i czegoś nie wie, z niej się dowie。 W niej jest praktycznie wszystko co było robione do 2007 roku。 Wrócę jeszcze do ceny。 90 parę zł to za dużo。 Na szczęście była wysprzedaż i lekturę można było kupić za coś koło 20 zł。 。。。more

Konstantinos

A well-written book with plenty of juicy technical details, that is strongly recommended to those who may find themselves writing BASH scripts longer than 50 lines on regular basis。 A must read for SysAdmin and DevOps professionals。

Frank

This is a reference text, not a book one would normally read cover-to-cover。 I've used it half-a-dozen times so far and it's proved useful。 *** [three stars]。 This is a reference text, not a book one would normally read cover-to-cover。 I've used it half-a-dozen times so far and it's proved useful。 *** [three stars]。 。。。more

Kawai

Works as advertised: A great desktop reference for simple bash commands and script snippets。 A quick way to learn, review, and integrate a wide range of bash into everyday sysadmin and developer practice。This is not a comprehensive, theory-driven overview of the bash shell, or an introduction to shell operations writ large; however, it's not intended for that, and users interested in a manual more along those lines would do better to read Learning the bash Shell。 Works as advertised: A great desktop reference for simple bash commands and script snippets。 A quick way to learn, review, and integrate a wide range of bash into everyday sysadmin and developer practice。This is not a comprehensive, theory-driven overview of the bash shell, or an introduction to shell operations writ large; however, it's not intended for that, and users interested in a manual more along those lines would do better to read Learning the bash Shell。 。。。more

Christopher

O'Reilly's "Cookbook" series sometimes gives complex recipes for large tasks, but unfortunately a lot of its listings are just the basic commands of the language in question。 That's the case with its Bash Cookbook。Thus one finds recipes like "How to separate variable names from surrounding text" (consisting of nothing more than an encouragement to use ${。。。}), "How to export variables" (which is only a mention of the "export" syntax), or "Renaming many files" (the solution is a simple for loop)。 O'Reilly's "Cookbook" series sometimes gives complex recipes for large tasks, but unfortunately a lot of its listings are just the basic commands of the language in question。 That's the case with its Bash Cookbook。Thus one finds recipes like "How to separate variable names from surrounding text" (consisting of nothing more than an encouragement to use ${。。。}), "How to export variables" (which is only a mention of the "export" syntax), or "Renaming many files" (the solution is a simple for loop)。 These are real basics of bash, or shells in general。 So, if you have already read O'Reilly's Learning the bash Shell and Classic Shell Scripting, which I would strongly recommend, then this book will not be of much use to you。 A proficient bash/Unix user would already know the vast majority of stuff in here。 If you have *not* read those or a comparable introduction to bash and Unix piped commands in general, then you won't really understand much this book, you would just be blindly copying commands。 And if you just want to cargo-cult code, then there are innumerable free resources on the web to do so, which you can reach with just a quick Google search of the form "bash" + problem。The book, already large, is padded with some appendices that are quite out of date: how to build bash from source (surely nearly every reader is using the version of bash shipped with his Linux distro), how to use version control (only the ancient RCS, CVS and SVN systems are described)。There is some meaty, still useful stuff in here like how to secure a shell script, so I cannot entirely knock the book, but mostly it duplicates content in the two rigorous bash/shell-scripting textbooks that I mentioned above。 。。。more

James

Accessible to bash newbies, with good explanations of commands' origins。 Accessible to bash newbies, with good explanations of commands' origins。 。。。more

José

This book is perfect。 There's no single page you read that you don't end with a real 'I didn\'t know that' feeling or at least a little piece of new information。 This book is perfect。 There's no single page you read that you don't end with a real 'I didn\'t know that' feeling or at least a little piece of new information。 。。。more

Aaron

Um。。。 a good overview, with lots of little details on how bash works。 There are places it isn't SUPER in depth, but for the most part it points you to other references then。 Um。。。 a good overview, with lots of little details on how bash works。 There are places it isn't SUPER in depth, but for the most part it points you to other references then。 。。。more